extends IBasicComponent


class_name IGuiable
"""
UI适配组件
"""


## 需要适配的Control面板
@export var wrapper: Control = null


func __check_exports() -> Dictionary:
    return IComponent.merge({
        "wrapper": IComponent.find_parent.bind(self, func(x): return x is Control, wrapper, 1),
    }, super.__check_exports())

func __init_hooks() -> Dictionary:
    return IComponent.merge({
        wrapper.gui_input: on_gui_input,
    }, super.__init_hooks())

func on_gui_input(event: InputEvent) -> void:
    pass
